﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using FileTransferProtocol;

namespace FileTransferClient
{
    public partial class dlgSelectDownLoadFile : Form
    {
        private List<TFileInfo> files = null;
        public dlgSelectDownLoadFile(List<TFileInfo> fileList)
        {
            InitializeComponent();
            files = fileList;
            this.gvFiles.DataSource = files;
        }
        
        public List<string> SelectFiles
        {
            get
            {
                List<string> selects = new List<string>();
                foreach (TFileInfo obj in gvFiles.SelectedRows)
                {
                    selects.Add(obj.File);
                }
                return selects;
            }
        }

        private void btnOK_Click(object sender, EventArgs e)
        {
            this.Close();
        }
    }
}
